package com.itheima.service.impl;

import com.itheima.mapper.SufferDao;
import com.itheima.domain.Patients;
import com.itheima.service.SufferService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SufferServiceImpl implements SufferService {
    @Autowired
    private SufferDao sufferDao;


    @Override
    public void save(Patients patients) {
        System.out.println(patients);
        sufferDao.save(patients);
        System.out.println(11);
    }

    @Override
    public List<Patients> findAll() {
        List<Patients> list=sufferDao.findAll();
        return list;
    }
}
